package com.boot.webflux.security.example2.module.service;


import com.boot.webflux.security.example2.module.dao.SysUserRepository;
import com.boot.webflux.security.example2.module.entity.SysRole;
import com.boot.webflux.security.example2.module.entity.SysUser;
import lombok.AllArgsConstructor;
import org.springframework.data.r2dbc.core.R2dbcEntityTemplate;
import org.springframework.stereotype.Service;
import reactor.core.publisher.Flux;

import java.util.List;

@Service
@AllArgsConstructor
public class SysUserService {
    private final R2dbcEntityTemplate template;
    private SysUserRepository sysUserRepository;

    public List<SysRole> selectSysRoleByUserId(Long userId) {
        return null;
    }

    public Flux<SysUser> getUserInfo(String username) {
        return sysUserRepository.findByUsername(username);
    }
}
